import request from "@/utils/request";

// 上传图片
export function uploadImageApi(data) {
  return request({
    url: "/common/images/upload",
    method: "post",
    headers: {
      "content-type": "multipart/form-data",
    },
    data,
  });
}

// 首页数据接口
export function getHomeDataApi(beginDate) {
  return request({
    url: `/firstPage/firstCount?beginDate=${beginDate}`,
    method: "get",
  });
}

// 获取oss通用配置
export function getTokenForOssUpload() {
  return request({
    url: "/aliyun/getTokenForOssUpload",
    method: "get",
  });
}

//查询系统中所有的来源渠道
export function getChannel(data) {
  return request({
    url: "/common/getChannel",
    method: "get"

  });
}